SeslAbsSeekBar

An abstract class extending SeslProgressBar that provides the foundation for SeslSeekBar, allowing users to set and customize a value within a specified range.

Main functionalities include:

  • Range Control: Set minimum and maximum values using setMin, setMax, or via the android:min and android:max attributes.
  • Progress Control: Set or get the current progress using setProgress, getProgress, or via the android:progress attribute.
  • Thumb Drawable: Customize the thumb using android:thumb, android:thumbOffset, android:thumbTint, and android:thumbTintMode attributes, or programmatically via setThumb and related methods.
  • Track Appearance: Control track width and mode using seslTrackMinWidth, seslTrackMaxWidth, seslSeekBarMode attributes, and programmatically via setMode.
  • Tick Marks: Customize tick marks using android:tickMark, android:tickMarkTint, and android:tickMarkTintMode attributes.
  • Split Track: Enable or disable split track mode using android:splitTrack attribute or setSplitTrack. When this is enabled, it separates the active range of track from the inactive range.
  • Dual Color Mode: Enable dual color track and set the overlap point using setOverlapPointForDualColor.
  • Seamless Dragging: Enable seamless thumb movement (higher scale) using setSeamless.
  • Disabled Alpha: Control disabled alpha using useDisabledAlpha and android:disabledAlpha attributes.
  • Thumb Radius: Set thumb radius using seslThumbRadius attribute.

Each mode (standard, warning, vertical, split, expand, expand vertical, level bar) provides a different visual appearance and behavior for the SeekBar, configurable via seslSeekBarMode attribute (don't use seekBarMode) or setMode.

See also

Inheritors

Constructors

Link copied to clipboard
constructor(context: Context)
constructor(context: Context, attrs: AttributeSet)
constructor(context: Context, attrs: AttributeSet, defStyleAttr: Int)
constructor(context: Context, attrs: AttributeSet, defStyleAttr: Int, defStyleRes: Int)

Types

Link copied to clipboard
open inner class SliderDrawable : Drawable
Link copied to clipboard
open inner class ThumbDrawable : Drawable

Properties

Link copied to clipboard
val NO_OVERLAP: Int = -1

Functions

Link copied to clipboard
open fun callSuperSetProgress(progress: Int)
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open fun drawTrack(canvas: Canvas)
Draws the progress bar track.
Link copied to clipboard
Returns the amount of progress changed via the arrow keys.
Link copied to clipboard
open fun getMax(): Int
Return the upper limit of this progress bar's range.
Link copied to clipboard
open fun getMin(): Int
Return the lower limit of this progress bar's range.
Link copied to clipboard
open fun getPaddingBottom(): Int
Link copied to clipboard
open fun getPaddingLeft(): Int
Link copied to clipboard
open fun getPaddingRight(): Int
Link copied to clipboard
open fun getPaddingTop(): Int
Link copied to clipboard
open fun getProgress(): Int
Get the progress bar's current level of progress.
Link copied to clipboard
Returns whether the track should be split by the thumb.
Link copied to clipboard
open fun getThumb(): Drawable
Return the drawable used to represent the scroll thumb - the component that the user can drag back and forth indicating the current value by its position.
Link copied to clipboard
Link copied to clipboard
open fun getThumbHeight(): Int
Link copied to clipboard
open fun getThumbOffset(): Int
Link copied to clipboard
Returns the tint applied to the thumb drawable, if specified.
Link copied to clipboard
Returns the blending mode used to apply the tint to the thumb drawable, if specified.
Link copied to clipboard
open fun getTickMark(): Drawable
Link copied to clipboard
Returns the tint applied to the tick mark drawable, if specified.
Link copied to clipboard
Returns the blending mode used to apply the tint to the tick mark drawable, if specified.
Link copied to clipboard
Link copied to clipboard
open fun onDraw(@NonNull canvas: Canvas)
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open fun onKeyChange()
Called when the user changes the seekbar's progress by using a key event.
Link copied to clipboard
open fun onKeyDown(keyCode: Int, event: KeyEvent): Boolean
Link copied to clipboard
open fun onProgressRefresh(scale: Float, fromUser: Boolean, progress: Int)
Link copied to clipboard
open fun onResolveDrawables(layoutDirection: Int)
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open fun onTouchEvent(event: MotionEvent): Boolean
Link copied to clipboard
open fun onVisualProgressChanged(id: Int, scale: Float)
Called when the visual state of a progress indicator changes.
Link copied to clipboard
open fun performAccessibilityAction(action: Int, arguments: Bundle): Boolean
Link copied to clipboard
open fun setDualModeOverlapColor(bgColor: Int, fgColor: Int)
Sets the overlap colors for the seekbar track
Link copied to clipboard
open fun setKeyProgressIncrement(increment: Int)
Sets the amount of progress changed via the arrow keys.
Link copied to clipboard
open fun setMax(max: Int)
Set the upper range of the progress bar max.
Link copied to clipboard
open fun setMin(min: Int)
Set the lower range of the progress bar to min.
Link copied to clipboard
open fun setMode(mode: Int)
Link copied to clipboard
Link copied to clipboard
Sets the point in the tract color where the overlap color will start
Link copied to clipboard
open fun setProgress(progress: Int)
Sets the current progress to the specified value.
Link copied to clipboard
Define the drawable used to draw the progress bar in progress mode.
Link copied to clipboard
open fun setProgressInternal(progress: Int, fromUser: Boolean, animate: Boolean): Boolean
Link copied to clipboard
Applies a tint to the progress indicator, if one exists, or to the entire progress drawable otherwise.
Link copied to clipboard
open fun setSeamless(seamless: Boolean)
Sets dragging of the thumb to be seamless or not.
Link copied to clipboard
open fun setSecondaryProgress(secondaryProgress: Int)
Set the current secondary progress to the specified value.
Link copied to clipboard
open fun setSplitTrack(splitTrack: Boolean)
Specifies whether the track should be split by the thumb.
Link copied to clipboard
Link copied to clipboard
open fun setThumb(thumb: Drawable)
Link copied to clipboard
open fun setThumbOffset(thumbOffset: Int)
Sets the thumb offset that allows the thumb to extend out of the range of the track.
Link copied to clipboard
open fun setThumbTintColor(color: Int)
Link copied to clipboard
Applies a tint to the thumb drawable.
Link copied to clipboard
Specifies the blending mode used to apply the tint specified by setThumbTintList} to the thumb drawable.
Link copied to clipboard
open fun setTickMark(tickMark: Drawable)
Sets the drawable displayed at each progress position, e.g.
Link copied to clipboard
Applies a tint to the tick mark drawable.
Link copied to clipboard
Specifies the blending mode used to apply the tint specified by setTickMarkTintList} to the tick mark drawable.
Link copied to clipboard
Link copied to clipboard
open fun updateHoverPopup()